package com.mew.common.rest.bo;

import io.netty.channel.Channel;
import lombok.*;

@Data
@ToString
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(of = {"userId"})
@Builder
public class GameSession {
    private long userId;
    private long tk;

    private Channel channel; //GW
    private boolean isWeakClose = false; //true: 弱关闭, false: 表示在线;  如果断线则直接移除

    private String vfx;
    private int gameId;
    private int roomId;
    private String roomBetArray;  //进入房间 加载 重连房间加载

    private String gid;
    private String nickname;
    private int headPath; // 头像
    private int userLevel;
    private int vipLevel;
    private long vipExpValue;
    private int whiteList;


    public boolean channelFine(){
        return  this.channel != null && this.channel.isActive();
    }
}
